package com.ff.xyh.access.controller.post;

import com.ff.xyh.access.service.post.PostJoinerFeignService;
import com.ff.xyh.common.entity.result.ResultObject;
import com.ff.xyh.common.qo.post.PostJoinerQuery;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @Auther FF
 * @Date 2023年 05月 24日
 * @Time 12:20
 */

@Api(tags = "帖子参与信息管理接口")
@RestController
@RequestMapping("/access/post/joiner")
public class PostJoinerController {

    @Autowired
    private PostJoinerFeignService service;

    @ApiOperation(value = "条件查询帖子参与信息列表")
    @PostMapping("get")
    ResultObject getPostJoinerCondition(
            @RequestBody PostJoinerQuery postJoinerQuery) {
        return service.getPostJoinerCondition(postJoinerQuery);
    }
    @ApiOperation(value = "删除帖子参与信息")
    @PostMapping("delete")
    ResultObject deletePostJoiner(
            @RequestParam("postId") String postId, @RequestParam("postType") Integer postType, @RequestParam("userId") String userId) {
        return service.deletePostJoiner(postId, postType, userId);
    }

}



